﻿namespace NavigationSampleWinForms.Views.Stack
{
    using System;

    using Smart.Navigation;

    /// <summary>
    /// 
    /// </summary>
    [View(ViewId.Stack1)]
    public partial class Stack1View : AppViewBase
    {
        /// <summary>
        /// 
        /// </summary>
        public Stack1View()
        {
            InitializeComponent();
        }

        /// <summary>
        /// 
        /// </summary>
        /// <param name="args"></param>
        public override void OnViewOpen(ViewForwardEventArgs args)
        {
            // ファンクションキー
            FunctionCotrol.UpdateFunctionKeys(null);
        }

        /// <summary>
        /// 
        /// </summary>
        public override void OnButtonExit()
        {
            Navigator.Forward(ViewId.Menu);
        }

        /// <summary>
        /// 
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void PrevButtonClick(object sender, EventArgs e)
        {
            Navigator.Forward(ViewId.Menu);
        }

        /// <summary>
        /// 
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void PushButtonClick(object sender, EventArgs e)
        {
            Navigator.Push(ViewId.Stack2);
        }
    }
}